﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BasketStats.Core.Team;
using BasketStats.Core.Stats;

namespace BasketStats.Core.Game
{
    public class Game
    {
        private ICollection<Player> m_team = new List<Player>();
        private ICollection<IGameFraction> m_gameFractions = new List<IGameFraction>();
        public IGameFraction CurrentQuarter { get; private set; }

        public IEnumerable<Player> Team
        {
            get
            {
                return m_team;
            }
        }

        public Game(IEnumerable<Player> team)
        {
            foreach (var player in team)
            {
                var stat = new Statistics();
                player.CurrentStatistics = (stat);
                m_team.Add(player);
            }
        }

        public void StartGame()
        {
            CurrentQuarter = new Quarter();
            m_gameFractions.Add(CurrentQuarter);
        }

        public void EndFraction()
        {
            
        }

    }
}
